<template>
  <el-button type="primary" plain icon="Pointer" @click="handleAdd" style="margin-left:20px;">指定专人审核</el-button>
  <el-button type="warning" plain icon="Download" @click="handleOut">导出</el-button>
  <el-table :data="WaitAssessorList" style="width: 95%;margin:20px;" size="large">
    <el-table-column type="selection" width="55" />
    <el-table-column prop="empName" label="员工姓名" width="150" >
        <template #default="scope">
            <el-tooltip
                content="点击开始审核"
                placement="top-start"
                effect="light">
                <a 
                style="text-decoration: none; color: black">
                {{ scope.row.empName }}
                </a>
            </el-tooltip>
        </template>
    </el-table-column>
    <el-table-column prop="position" label="岗位" width="180"></el-table-column>
    <el-table-column prop="third" label="三级单元" width="120" />
    <el-table-column prop="fourth" label="四级单元" width="120" />
    <el-table-column label="操作">
      <template #default="scope">
        <el-button 
        type="success"
         @click="onShowClick(scope.$index, scope.row)"
          >重审</el-button
        >
        <!--<el-button
          @click="handleDelete(scope.$index, scope.row)"
          >指定专人重审</el-button
        >-->
      </template>
    </el-table-column>
  </el-table>
</template>


<script setup>
import {ref, onMounted,onBeforeMount, reactive} from "vue";
import { Timer } from '@element-plus/icons-vue';
import {useRouter} from "vue-router";
import {getBackWageKpi} from '@/api/task'

const router = useRouter()

const WaitAssessorList=ref([])
onBeforeMount(()=>{
  let empId=JSON.parse(localStorage.getItem('userInfo')).id;
    getBackWageKpi({empId})
    .then(data=>{
        WaitAssessorList.value=data.data;
    });
    
})

const onShowClick =(index, row) => {
  router.push({
    path: '/back/AuditDetial',
    query: row
  })

}

</script>

<style lang="scss" scoped>

</style>
